Simple GC - Safe Compilation

نویسنده

  • Hans-J Boehm
چکیده

Xerox PARC 8/13/91 It is increasingly attractive to compile programming languages requiring garbage collection into a standard intermediate language. This allows readily available translators for the intermediate language to be used in targeting an increasing variety of architectures, and thus allows an implementation that is immediately portable across a variety of architectures. The intermediate language most commonly used for this purpose is the C programming language. Lisp, and others. In several cases, these are the only currently viable implementations of the respective language. The reason for this is no doubt that C compilers target more different architectures than translators for other candidate languages. Furthermore every major hardware manufacturer provides a C compiler, which can thus take advantage of all instruction timing information known to the hardware manufacturer. This makes it difficult for third party compilers for other languages to provide comparable performance. The following proposal also applies to other intermediate languages. However, due to the dominance of C as an intermediate language, we cast the proposal in terms of C. We are careful to state the proposal such that it is also applicable to handwritten C, both because this is useful in itself, and because any other proposal would be unrealistic. In order to facilitate the discussion, we refer to the original source language as L. A fundamental difficulty with using standard C in conjunction with a garbage collector is that the C compiler is unlikely to cooperate with the collector in any major way. It cannot be expected to generate tables describing data structure layout to the garbage collector, or to adhere to conventions that clearly identify pointers. In fact, it has no way to generate such information, since it is often difficult to generate or write C programs with reliable type information in the C source. Most C-generating compilers appear to emit misleading C type information. However, the C compiler is free to choose it's own data structure layout, at least for function activation records, thus making it essentially impossible for the L-to-C compiler to emit such information. A number of techniques have been proposed to eliminate the need for compiler generated data layout information. Edelson proposes a method based on explicit root registration [Edelson 90]. Most other approaches rely on conservatively traversing at least the program stack and registers, treating all bit patterns that correspond to object pointers as though they were objects pointers. Currently all approaches …

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Type-Safe Trading Proxies Using TORBA

Nowadays, Autonomous Distributed Systems, such as large-scaled telecom and manufacturing applications, rely on the use of middleware. In order to find back resources and to interconnect applications, the middleware has to provide a trading function. Unfortunately, standard traders such as the ODP/OMG CosTrading service, are error-prone due to the lack of type checking at compilation time, but o...

متن کامل

A Formal Framework for Java Separate Compilation

We define a formal notion, called compilation schema, suitable for specifying different possibilities for performing the overall process of Java compilation, which includes typechecking of source fragments with generation of corresponding binary code, typechecking of binary fragments, extraction of type information from fragments and definition of dependencies among them. We consider three comp...

متن کامل

Data Flow Analysis as a General Concept for the Transport of Verifiable Program Annotations

Just-in-Time (JIT) compilation is frequently employed in order to speed-up the execution of platform-independent and dynamically extensible mobile code applications. Since the time required for dynamic compilation directly influences a program’s execution time, JIT compilers usually utilize only simple and fast techniques for program analysis and optimization. To improve further the analysis an...

متن کامل

JikesRVM: Internal Mechanisms Study and Garbage Collection with MMTk

High Level Language Virtual Machines is a core topic of interest for the researchers who are into virtual execution environments. As an open source virtual machine released to 16 universities, as early as 2001, Jikes RVM has been a major drive for many researches. While working on this project, we studied the JIT compilation of Jikes RVM as well as the Garbage Collection (GC) which is handled b...

متن کامل

Certifying Compilation and Run-Time Code Generation

A certifying compiler takes a source language program and produces object code as well as a certi cate that can be used to verify that the object code satis es desirable prop erties such as type safety and memory safety Certifying compilation helps to increase both compiler robustness and program safety Compiler robustness is improved since some compiler errors can be caught by checking the obj...

متن کامل

Cycler: Improve Tracing Garbage Collection with Real-time Object Reuse

Tracing garbage collection (GC) identifies dead objects by scanning the object-graph from the root set references. It is proven to be highly efficient and widely used in commercial managed runtime systems for Java, C# and scripting languages. However, tracing GC cannot identify the dead objects before finishing object-graph traversal. Hence the application cannot reuse the space of the dead obj...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 1991